package com.xiaoyu.awakening.ai.index.core.chunk.model;

import lombok.Builder;
import lombok.Data;

import java.util.List;
import java.util.Map;

/**
 * 文件分块结构
 *
 * @author wangxiaoyu
 * @date 2025/7/22 11:27
 * @since v1.0
 */
@Data
@Builder
public class AwkDocChunk {
    private String docId;
    private String docText;
    private List<AwkDocChunkNode> chunkNodeList;
    private List<AwkDocChunkEdge> chunkEdgeList;
    private ChunkType chunkType;

    public boolean addChunk(AwkDocChunkNode node) {
        return false;
    }

    public boolean addEdge(AwkDocChunkEdge edge) {
        return false;
    }

    public enum ChunkType {
        // 普通
        COMMON,
        // 树型
        TREE,
        // 图型
        GRAPH,
        // 自定义
        CUSTOM
    }

    public static class AwkDocChunkNode {
        private String chunkId;
        private String chunkText;
        private Map<String, Object> properties;
    }

    public static class AwkDocChunkEdge {
        private String sourceChunkId;
        private String targetChunkId;
        private Map<String, Object> properties;
    }

}
